-
Notifications
You must be signed in to change notification settings - Fork 4k
.Net: SK integration with MEAI Abstractions #10754
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…nts) Phase 1 (#10651) ### Motivation and Context - Resolves partially #10319 This change adds a new `IChatClientSelector` abstraction to work without breaking current `IAIServiceSelector` implementations. This was necessary because `Kernel` now will be able to resolve `IChatClient`s which are not `IAIService` implementations, and `OrderedAIServiceSelector` now can select not only `AIServices` but `ChatClients` as well by implementing the `IChatClientSelector` interface. All other changes are related to test accepting `IChatClient`s added to the `Service` DI container, ensuring they work as expected together with current `IChatCOmpletionService` and `ITextGenerationService` in the `Kernel`.
…nto upstream/feature-msextensions-ai
…1049) # Add ChatClient Support to ChatCompletionAgent - Resolve #10729 ## Motivation and Context This PR enhances ChatCompletionAgent to support `IChatClient` alongside existing IChatCompletionService, providing more flexibility in how chat completions are handled. This enables better integration with existing `Microsoft.Extensions.AI` types. ## Description ### Core Changes 1. Enhanced ChatCompletionAgent to: - Support both IChatClient and IChatCompletionService interfaces - Maintain backward compatibility with existing implementations 2. Updated Sample Code: - Added new examples in Concepts demonstrating ChatClient usage - Updated Getting Started With Agents samples to showcase both service types 3. Added Comprehensive Unit Tests: - Test coverage for Agents with ChatClient integration - Verification of both streaming and non-streaming scenarios 4. Added `IChatClient.AsKernelFunctionInvokingClient` extension method to enable Kernel Function Invocation support with `IChatClient` for solutions that target `.NET 8 LTS` only.
…nto upstream/feature-msextensions-ai
…t/semantic-kernel into feature-msextensions-ai
…nto feature-msextensions-ai
markwallace-microsoft
approved these changes
May 20, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All changes have been reviewed on their way into the feature branch
SergeyMenshykh
approved these changes
May 20, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
kernel.core
kernel
Issues or pull requests impacting the core kernel
.NET
Issue or Pull requests regarding .NET code
PR: in progress
Under development and/or addressing feedback
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Microsoft Extensions AI Integration
This PR brings native integration to majority of
Microsoft.Extensions.AI
abstractions into Semantic Kernel components and API's.Including:
Kernel
andDI
Containers #10727Kernel
andDI
. #10729Kernel
Filters
#10730